/**
 * @FileName: DblGattAttributes.java
 * @Package:com.bdtop.dbl.bluetooth
 * @Description: TODO
 * @author: MingjunLi
 * @date:2014-9-26
 * @version V1.0
 */
package com.bdtop.dbl.bluetooth;

import java.util.UUID;

import com.bdtop.dbl.utils.DblUtils;

/**
 * @ClassName: DblGattAttributes
 * @Description: TODO
 * @author: MingjunLi
 * @date:2014-9-26
 */
public class DblGattAttributes {

	// GATT Service
	public static final UUID SERVICE_LINK_LOSS = UUID.fromString("00001803-0000-1000-8000-00805f9b34fb");

	public static final UUID SERVICE_GENERIC_ACCESS_PROFILE = UUID.fromString("00001800-0000-1000-8000-00805f9b34fb");

	public static final UUID SERVICE_KEY_EVENT = UUID.fromString("0000ffe0-0000-1000-8000-00805f9b34fb");

	public static final UUID SERVICE_GENERIC_ATTR_PROFILE = UUID.fromString("00001801-0000-1000-8000-00805f9b34fb");

	public static final UUID SERVICE_BATTERY = UUID.fromString("0000180f-0000-1000-8000-00805f9b34fb");

	public static final UUID SERVICE_ALERT = UUID.fromString("00001802-0000-1000-8000-00805f9b34fb");

	public static final UUID SERVICE_MANUFACTURER = UUID.fromString("00002a29-0000-1000-8000-00805f9b34fb");

	public static final UUID SERVICE_LIGHT = UUID.fromString("0000fff1-0000-1000-8000-00805f9b34fb");

	// GATT Characteristic
	public static final UUID IMMEDIATE_ALERT_LEVEL = UUID.fromString("00002a06-0000-1000-8000-00805f9b34fb");

	public static final UUID BATTERY_ALERT_LEVEL = UUID.fromString("00002a19-0000-1000-8000-00805f9b34fb");

	public static final UUID CLIENT_CHARACTERISTIC_CONFIG = UUID.fromString("00002902-0000-1000-8000-00805f9b34fb");

	public static final UUID HEART_RATE_MEASUREMENT = UUID.fromString("0000ffe1-0000-1000-8000-00805f9b34fb");

	// Write Values
	public static final byte[] VALUE_STOP_ALERT = { 0x00 };
	public static final byte[] VALUE_LOW_ALERT = { 0x01 };
	public static final byte[] VALUE_HIGH_ALERT = { 0x02 };

	/** 2015 蓝牙 new api 接口 */
	// 服务
	/** 广播服务【服务UUID：0xFE20】 */
	public static final UUID SERVICE_BLE = UUID.fromString("0000fe20-0000-1000-8000-00805f9b34fb");
	// 属性
	/** 控制参数通道【特征值UUID：0xFE21】 */
	public static final UUID PARAMS_CONTROL = UUID.fromString("0000fe21-0000-1000-8000-00805f9b34fb");
	/** RSSI更新通道【服务UUID：0xFE24】 */
	// 返回 默认值为0。 比如RSSI为-59dBm.参数为0xE3。
	public static final UUID PARAMS_RSSI = UUID.fromString("0000fe24-0000-1000-8000-00805f9b34fb");
	/** 按键响应通道【服务UUID：0xFE23】 */
	public static final UUID PARAMS_CALL = UUID.fromString("0000fe23-0000-1000-8000-00805f9b34fb");
	// 值
	/** 控制参数通道 */
	// 关机使能 NO(0)~YES(1) 默认值为YES。 YES－>无操作。 NO－>立即关机。
	// 使能防丢功能 NO(0)~YES(1) 默认值为0。 NO－>无操作 YES－>断开时报警提示。
	// 报警模式 0~3 默认值为0。 0－>停止报警 1－>提示声音 2－>警告模式 3－>报警模式
	// 连接间隙 1~49 默认值为10。 单位时间为10*10mS=100mS。
	public static final byte[] VALUE_CONTORL            = { 0x01, 0x01, 0x00, 0x10 };
	public static final byte[] VALUE_CONTORL_CALL       = { 0x01, 0x01, 0x03, 0x10 };
	public static final byte[] VALUE_CONTORL_STOP_ALTER = { 0x01, 0x01, 0x00, 0x10 };
	public static final byte[] VALUE_DUANKAI            = { 0x01, 0x00, 0x00, 0x10 };
	
}
